package com.example.oauth2.repository;


import com.example.oauth2.entry.RefreshToken;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

public interface RefreshTokenRepository extends JpaRepository<RefreshToken, String> {
    RefreshToken findOAuthRefreshTokenByTokenId(String tokenId);
    List<RefreshToken> findAll();
    @Transactional
    void deleteOAuthRefreshTokenByTokenId(String tokenId);
}
